package uplb.ics.cs190.e2d.test;

import uplb.ics.cs190.e2d.core.Game;
import uplb.ics.cs190.e2d.display.Graphics;
import uplb.ics.cs190.e2d.graphics.Color;
import uplb.ics.cs190.e2d.graphics.Image;
import uplb.ics.cs190.e2d.math.Dimension;

public class SampleGame extends Game {

	public Image image;
	
	@Override
	public String getTitle() {
		return "Sample Game 1.0.0";
	}

	@Override
	public Image getIcon() {
		return null;
	}

	@Override
	public Dimension getSize() {
		return new Dimension(640, 480);
	}

	@Override
	public void initResources() {
		image = getImage("sample.png");
		image.getWidth();
	}

	@Override
	public void destroy() {

	}

	@Override
	public boolean isFullScreen() {
		return false;
	}

	@Override
	public boolean useBufferStrategy() {
		return true;
	}

	@Override
	public boolean useVsync() {
		return true;
	}

	@Override
	public boolean isOpenGL() {
		return false;
	}

	@Override
	public void render(Graphics g) {
		g.setColor(Color.RED);
		g.fillRect(0, 0, 640, 480);
		image.render(g, 10, 10);
	}

	@Override
	public void update(long elapsedTime) {

	}
}
